CC=gcc 
CFLAGS=-I./include -lcrypto -lpthread -pthread -Wall -g 
SRC1=src/server.c
SRC2=src/client.c
SRC3=src/hash.c
HEAD=backup.h
all: server client clean

server : server.o
	$(CC) $(CFLAGS) -o bin/$@ $^ -lcrypto

server.o : $(SRC1) $(HEAD)
	$(CC) $(CFLAGS) -c -o $@ $(SRC1) -lcrypto
	
client : client.o
	$(CC) $(CFLAGS) -o bin/$@ $^ -lcrypto

client.o : $(SRC2) $(HEAD)
	$(CC) $(CFLAGS) -c -g -o $@ $(SRC2) -lcrypto
	
backup.h:

install: all
	cp bin/server /usr/bin/myClient
	cp bin/server /usr/bin/myServer
	
.PHONY : clean
clean:
	rm -rf *.o

.PHONY : uninstall	
uninstall:
	rm -rf bin/server
	rm -rf bin/client

	